Skip to content

Local TIFF support#131

Merged
chaichontat merged 13 commits intomainfrom
autotif
Mar 20, 2026
Merged

Local TIFF support#131
chaichontat merged 13 commits intomainfrom
autotif

Conversation

@chaichontat
Copy link
Owner

@chaichontat chaichontat commented Mar 14, 2026

  • You can now drag and drop local .tif and .tiff files directly into Samui for image-only viewing without first preparing a full sample folder.
  • Image control bar no longer collapses while you are still interacting with it with more and a button for expansion is introduced.

- Added support for local TIFF images, including view options and data source creation.
- Implemented percentile-based default intensity estimation for composite images.
- Updated image control state management to handle new image defaults.
- Enhanced background image rendering logic to accommodate local TIFF sources.
- Introduced new utility functions for estimating composite min-max values.
- Improved map resolution handling for GeoTIFF images.
- Added tests for new functionality, including local TIFF handling and intensity estimation.

Signed-off-by: Chaichontat Sriworarat <[email protected]>
…alues and overviews

- Added tests to ensure histogram allocation is managed correctly when extreme outliers are present in imgIntensity.
- Introduced a GuardedUint32Array to prevent oversized histograms in imgIntensity.
- Updated imgIntensity to clamp histogram values and optimize memory usage.
- Enhanced localTiffSource to build overview levels dynamically based on image dimensions.
- Modified resolution calculations for local TIFF images to include intermediate zoom levels.
- Updated Mapp class to conditionally show scale line based on image properties.
- Added type definitions for jpegxr module to support JPEG XR image decoding.

Signed-off-by: Chaichontat Sriworarat <[email protected]>
…d enhance splash page instructions

Signed-off-by: Chaichontat Sriworarat <[email protected]>
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Mar 14, 2026

Deploying loopy-browser with  Cloudflare Pages  Cloudflare Pages

Latest commit: 2c49102
Status: ✅  Deploy successful!
Preview URL: https://5ccf2156.loopy-browser.pages.dev
Branch Preview URL: https://autotif.loopy-browser.pages.dev

View logs

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ebe7805a06

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +143 to +145
const nonSpatialAxes = parsed.axes.replace(/[XY]/g, '');
if (channelAxis < 0 || nonSpatialAxes !== 'C') {
return null;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Accept singleton time/depth axes in JSON TIFF metadata

parseImageDescriptionChannelMetadata currently rejects any non-spatial axes combination except exactly "C", so metadata like {"axes":"TCYX","shape":[1,2,...]} or {"axes":"ZCYX","shape":[1,2,...]} is treated as unsupported even though it is still a valid 2D channel stack. In those cases explicitChannelNames becomes null and validateTiffLayout rejects the import, so legitimate TIFFs with singleton T/Z dimensions cannot be loaded.

Useful? React with 👍 / 👎.

@chaichontat chaichontat merged commit 3fab042 into main Mar 20, 2026
4 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant